Remove opcache from php-ext-install#19628
Conversation
In 8.5, `opcache` is now built-in (and since pretty recently, it's been enabled-by-default in the PHP images too).
| docker-php-ext-enable opcache 2>&1 | ||
| php -d display_errors=stderr -r 'exit(extension_loaded("Zend OPcache") ? 0 : 1);' | ||
| grep -q '^zend_extension=' /usr/local/etc/php/conf.d/*opcache*.ini | ||
| # TODO now that opcache is built-in (8.5+), we could use a new zend_extension to test that they're loaded correctly too 🙈 |
There was a problem hiding this comment.
To this point, there's something in there called zend_test, but it requires libxml to compile so I didn't want to completely refactor this test just so we keep testing loading zend_extensions, especially since they're so rare.
|
|
||
| # opcache is pre-built by default at least as far back as PHP 5.5 | ||
| docker-php-ext-enable opcache 2>&1 | ||
| php -d display_errors=stderr -r 'exit(extension_loaded("Zend OPcache") ? 0 : 1);' |
There was a problem hiding this comment.
this test can stay - https://3v4l.org/auMnl/rfc#vgit.master, it only does not have to/can be enabled manually/explicitly
There was a problem hiding this comment.
Oh nice, but it's the docker-php-ext-enable opcache bit that this was actually important for (making sure that switched from extension= to zend_extension= transparently), and that broke. In hindsight, it looks like we could've maybe swapped to docker-php-ext-install opcache instead, but that fails like this in PHP 8.5.0beta1:
Installing shared extensions: /usr/local/lib/php/extensions/no-debug-non-zts-20240925/
cp: cannot stat 'modules/*': No such file or directory
make: *** [Makefile:89: install-modules] Error 1
In 8.5,
opcacheis now built-in (and since pretty recently, it's been enabled-by-default in the PHP images too).See also: